package com.example.demo.day.config.learn.design.proxy.x1;

//律师 (也实现了诉讼接口)
public class Lawer implements ILawsuit{
    private ILawsuit iLawsuit;

    public Lawer(ILawsuit iLawsuit) {
        this.iLawsuit = iLawsuit;
    }

    @Override
    public void summit() {
        System.out.println("律师：是否要提交诉讼？");
        iLawsuit.summit();
        System.out.println("律师：已向法院提起诉讼");
    }

    @Override
    public void burden() {
        System.out.println("律师：请提供相关证据.");
        iLawsuit.burden();
        System.out.println("律师：已提供相关证据到法院");
    }


    @Override
    public void defend() {
        System.out.println("律师：开庭辩护，是否可以私下协商解决？");
        iLawsuit.defend();
        System.out.println("律师：等待法院的判决结果");
    }

    @Override
    public void finish() {
        System.out.println("律师：已收到法院的判决结果？");
        iLawsuit.finish();
        System.out.println("律师：结案");
    }
}
